﻿using System;
using System.Collections.Generic;
using System.Text;
using NetworkLib.Utilities;
using PBO.Network;

namespace PokemonBattle.BattleRoom.Client
{
    public class FourPlayerRoom : DataByteArray
    {
        public string Name { get; set; }
        public int Identity { get; set; }
        public byte PlayerCount { get; set; }

        #region abstract

        public override void Read(ByteArray byteArray)
        {
            this.Name = byteArray.ReadUTF();
            this.Identity = byteArray.ReadInt();
            this.PlayerCount = byteArray.ReadByte();
        }

        public override void Write(ByteArray byteArray)
        {
            byteArray.WriteUTF(this.Name);
            byteArray.WriteInt(this.Identity);
            byteArray.WriteByte(this.PlayerCount);
        }

        #endregion

    }
}
